From fee33a543d191ca93a2fed3ab38fb354524dd8d8 Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Mon, 28 Jun 1999 07:06:01 +0000 Subject: [PATCH] bpl was set wrong for bitmaps, should be multiple of 4. (Thanks to Hans * gdk/win32/gdkimage.c (gdk_image_get): bpl was set wrong for bitmaps, should be multiple of 4. (Thanks to Hans Breuer for finding this.) --- ChangeLog | 6 ++++++ ChangeLog.pre-2-0 | 6 ++++++ ChangeLog.pre-2-10 | 6 ++++++ ChangeLog.pre-2-2 | 6 ++++++ ChangeLog.pre-2-4 | 6 ++++++ ChangeLog.pre-2-6 | 6 ++++++ ChangeLog.pre-2-8 | 6 ++++++ gdk/win32/gdkimage-win32.c | 2 +- gdk/win32/gdkimage.c | 2 +- 9 files changed, 44 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 48708f795c..b017826940 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Mon Jun 28 10:03:07 1999 Tor Lillqvist + + * gdk/win32/gdkimage.c (gdk_image_get): bpl was set wrong for + bitmaps, should be multiple of 4. (Thanks to Hans Breuer for + finding this.) + 1999-06-01 Jose H Mercado * gtk+.spec.in: Corrected some typos in files section. diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 48708f795c..b017826940 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,9 @@ +Mon Jun 28 10:03:07 1999 Tor Lillqvist + + * gdk/win32/gdkimage.c (gdk_image_get): bpl was set wrong for + bitmaps, should be multiple of 4. (Thanks to Hans Breuer for + finding this.) + 1999-06-01 Jose H Mercado * gtk+.spec.in: Corrected some typos in files section. diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 48708f795c..b017826940 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,9 @@ +Mon Jun 28 10:03:07 1999 Tor Lillqvist + + * gdk/win32/gdkimage.c (gdk_image_get): bpl was set wrong for + bitmaps, should be multiple of 4. (Thanks to Hans Breuer for + finding this.) + 1999-06-01 Jose H Mercado * gtk+.spec.in: Corrected some typos in files section. diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 48708f795c..b017826940 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,9 @@ +Mon Jun 28 10:03:07 1999 Tor Lillqvist + + * gdk/win32/gdkimage.c (gdk_image_get): bpl was set wrong for + bitmaps, should be multiple of 4. (Thanks to Hans Breuer for + finding this.) + 1999-06-01 Jose H Mercado * gtk+.spec.in: Corrected some typos in files section. diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 48708f795c..b017826940 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,9 @@ +Mon Jun 28 10:03:07 1999 Tor Lillqvist + + * gdk/win32/gdkimage.c (gdk_image_get): bpl was set wrong for + bitmaps, should be multiple of 4. (Thanks to Hans Breuer for + finding this.) + 1999-06-01 Jose H Mercado * gtk+.spec.in: Corrected some typos in files section. diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 48708f795c..b017826940 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,9 @@ +Mon Jun 28 10:03:07 1999 Tor Lillqvist + + * gdk/win32/gdkimage.c (gdk_image_get): bpl was set wrong for + bitmaps, should be multiple of 4. (Thanks to Hans Breuer for + finding this.) + 1999-06-01 Jose H Mercado * gtk+.spec.in: Corrected some typos in files section. diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 48708f795c..b017826940 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,9 @@ +Mon Jun 28 10:03:07 1999 Tor Lillqvist + + * gdk/win32/gdkimage.c (gdk_image_get): bpl was set wrong for + bitmaps, should be multiple of 4. (Thanks to Hans Breuer for + finding this.) + 1999-06-01 Jose H Mercado * gtk+.spec.in: Corrected some typos in files section. diff --git a/gdk/win32/gdkimage-win32.c b/gdk/win32/gdkimage-win32.c index 8b8c4190ea..790d385297 100644 --- a/gdk/win32/gdkimage-win32.c +++ b/gdk/win32/gdkimage-win32.c @@ -522,7 +522,7 @@ gdk_image_get (GdkWindow *window, } image->byte_order = GDK_LSB_FIRST; if (image->depth == 1) - image->bpl = (width - 1)/8 + 1; + image->bpl = ((width - 1)/32 + 1)*4; else image->bpl = ((width*image->bpp - 1)/4 + 1)*4; diff --git a/gdk/win32/gdkimage.c b/gdk/win32/gdkimage.c index 8b8c4190ea..790d385297 100644 --- a/gdk/win32/gdkimage.c +++ b/gdk/win32/gdkimage.c @@ -522,7 +522,7 @@ gdk_image_get (GdkWindow *window, } image->byte_order = GDK_LSB_FIRST; if (image->depth == 1) - image->bpl = (width - 1)/8 + 1; + image->bpl = ((width - 1)/32 + 1)*4; else image->bpl = ((width*image->bpp - 1)/4 + 1)*4; -- 2.30.2